<?php

namespace Xin\Hint\ThinkPHP;

use think\Response;

class ApiRender extends AbstractRender
{

	/**
	 * @inheritDoc
	 */
	public function render($data = null, array $options = [])
	{
		return Response::create($this->optimizeData($data), 'json');
	}

	/**
	 * @inheritDoc
	 */
	public function isAjax()
	{
		return true;
	}

}
